package com.smart.community.feign.appointment;

import com.smart.community.commons.result.Result;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * 预约服务Feign降级处理
 * 
 * @author Wu.Liang
 */
@Slf4j
@Component
public class AppointmentFeignClientFallback implements AppointmentFeignClient {
    
    @Override
    public Result<?> getAppointmentRecords(Long userId) {
        log.warn("预约记录服务调用失败，用户ID: {}", userId);
        return Result.fail("预约记录服务暂时不可用");
    }
    
    @Override
    public Result<?> getAppointmentStatus(Long appointmentId) {
        log.warn("预约状态服务调用失败，预约ID: {}", appointmentId);
        return Result.fail("预约状态服务暂时不可用");
    }
    
    @Override
    public Result<?> getAvailableTime(Long serviceId) {
        log.warn("可用时间服务调用失败，服务ID: {}", serviceId);
        return Result.fail("可用时间服务暂时不可用");
    }
} 
